<?php

namespace App\Http\Controllers\Index;

use App\Models\Banner\LiveBanner;
use Illuminate\Http\Request;
use App\Http\Controllers\Controller;

class BannerController extends Controller
{
    public function index(Request $request)
    {
        $type = $request->input('type');
        if (empty($type)) {
            return self::response(null,'-1','类型为空');
        }
        $data = LiveBanner::getBannerByType($type);
        return self::response($data,'200');
    }
}
